package com.shensi.api.admin.client.station;

import com.shensi.api.admin.client.fallback.monitor.SysLogininforClientFallBack;
import com.shensi.api.admin.domian.station.dto.StationNoticeDto;
import com.shensi.api.admin.domian.station.dto.SyncUserDto;
import com.shensi.common.core.annotation.Log;
import com.shensi.common.core.constant.CloudConstant;
import com.shensi.common.core.domain.AjaxResult;
import com.shensi.common.core.enums.BusinessType;
import com.shensi.common.core.page.TableDataInfo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestBody;

import javax.validation.Valid;
import java.util.List;


/**
 * @author mao
 */
@FeignClient(
        value = CloudConstant.ADMIN_SERVER,
        fallbackFactory = SysLogininforClientFallBack.class)
@Component
public interface StationNoticeClient {

    /**
     * 查询油站通知管理列表
     */
    @GetMapping("/station/notice/list")
    public TableDataInfo list(StationNoticeDto stationNotice);

    /**
     * 导出油站通知管理列表
     */
    @GetMapping("/station/notice/export")
    public AjaxResult export(StationNoticeDto stationNotice);

    /**
     * 获取油站通知管理详细信息
     */
    @GetMapping(value = "/station/notice/{noticeId}")
    public AjaxResult getInfo(@PathVariable("noticeId") Long noticeId);

    /**
     * 新增油站通知管理
     */
    @PostMapping("/station/notice")
    public AjaxResult add(@RequestBody StationNoticeDto stationNotice);

    /**
     * 修改油站通知管理
     */
    @PutMapping("/station/notice")
    public AjaxResult edit(@RequestBody StationNoticeDto stationNotice);

    /**
     * 删除油站通知管理
     */
    @DeleteMapping("/station/notice/{noticeIds}")
    public AjaxResult remove(@PathVariable("noticeIds") Long[] noticeIds);
}
